HSLColorUtil

open class HSLColorUtil

Utilities for using Hue, Saturation, Luminance (HSL) colors and converting to/from standard Color objects.

Author

Kevin Menningen

Properties

Link copied to clipboard
val HUE_INDEX: Int = 0
A convenience repeat of the index for the hue value in hue, saturation and luminance array return values.
Link copied to clipboard
A convenience repeat of the index for the luminance value in hue, saturation and luminance array return values.
Link copied to clipboard
A convenience repeat of the index for the saturation value in hue, saturation and luminance array return values.

Functions

Link copied to clipboard
open fun convertHSLtoRGB(hue: Float, saturation: Float, luminance: Float): Color
Convert a hue, saturation and luminance color value to the standard AWT Color object.
Link copied to clipboard
open fun convertRGBtoHSL(inColor: Color): Array<Float>
Convert a standard AWT color to hue, saturation and luminance.
Link copied to clipboard
open fun getLighterColor(hslColor: Array<Float>, amount: Float): Color
Make a dark color lighter (more luminance) by a specified amount.